package com.sunyard.constant;

public class BaseResp {
    private int code;
    private String message;

    public BaseResp() {
        code = 0;
        message = "ok";
    }

    public BaseResp(IResult result) {
        code = result.getCode();
        message = result.getMessage();
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public void setResult(IResult result) {
        code = result.getCode();
        message = result.getMessage();
    }
}
